package com.bed.lovewithpatientbed.service;

import com.bed.lovewithpatientbed.pojo.Permission;
import com.bed.lovewithpatientbed.pojo.RolePermission;

import java.util.List;

/**
 * @author xuxiaoding
 * @version 1.0.0
 * @ClassName IPermissionService.java
 * @Description TODO
 */
public interface IPermissionService {

    /**
     * @title getPermissionByRoleIdFromRolePermission
     * @description 根据 roleId 从 role_permission
     * @author xuxiaoding
     * @param roleId 角色 id
     * @return Permission 集合
     */
    List<RolePermission> getRolePermissionByRoleId(Integer roleId);

    /**
     * @title getPermissionByPermissionId
     * @description 根据多个 permissionId 获取 Permission 集合
     * @author xuxiaoding
     * @param permissions permissionId 集合
     * @return 返回查询结果
     */
    List<Permission> getPermissionByPermissionId(List<Integer> permissions);
    
    /**
     * @title getPermissionByPermissionId
     * @description 根据 permissionId 查询 permission
     * @author xuxiaoding
     * @param permissionId
     * @return 返回查询结果
     */
    Permission getPermissionByPermissionId(Integer permissionId);
}
